from django.urls import path
from .views import (
    MarketIndicesView, IndexDailyKLineView, IndexMinuteDataView, 
    IndexWeeklyKLineView, IndexMonthlyKLineView, MarketDistributionView,
    MarketTrendView,MarketEnergyView,StockMinuteView,StockEnergyZtView,
    StockDailyKLineView,StockWeeklyKLineView,StockMonthlyKLineView,StockInfoView
)

urlpatterns = [
    # path('', fetch_data),  # 保留根端点作为备用
    path('market/indices/', MarketIndicesView.as_view(), name='market-indices'),
    path('market/distribution/', MarketDistributionView.as_view(), name='market-distribution'),
    path('market/trend/', MarketTrendView.as_view(), name='market-trend'),
    path('market/kline/daily/', IndexDailyKLineView.as_view(), name='market-kline-daily'),
    path('market/kline/weekly/', IndexWeeklyKLineView.as_view(), name='market-kline-weekly'),
    path('market/kline/monthly/', IndexMonthlyKLineView.as_view(), name='market-kline-monthly'),
    path('market/tick/', IndexMinuteDataView.as_view(), name='market-tick'),
    path('market/energy/', MarketEnergyView.as_view(), name='market-energy'),
    path('stock/tick/', StockMinuteView.as_view(), name='stock-tick'),
    path('stock/kline/daily/', StockDailyKLineView.as_view(), name='stock-kline-daily'),
    path('stock/kline/weekly/', StockWeeklyKLineView.as_view(), name='stock-kline-weekly'),
    path('stock/kline/monthly/', StockMonthlyKLineView.as_view(), name='stock-kline-monthly'),
    path('stock/info/', StockInfoView.as_view(), name='stock-info'),
    path('stock/energy-zt/',StockEnergyZtView.as_view(), name='stock-energy-zt'),
]